<template>
  <div :style="{'line-height': types==='list'?'20px':''}">
    <span v-if="data.creditInfo&&data.creditInfo.creditStatus==='1'">已设置</span>
    <span v-else>未设置</span>
    <br v-if="types==='list'">
    <span
      v-if="data.creditInfo&&data.creditInfo.processDefinitionKey==='creditCreate'&&data.creditInfo.flowStatus==='DOING'"
      class="flow-status-color"
      style="padding:0px 4px"
    >[设置信用审核中]</span>
    <span
      v-if="data.creditInfo&&data.creditInfo.processDefinitionKey==='creditCreate'&&data.creditInfo.flowStatus==='REFUSE'"
      class="flow-status-color"
      style="padding:0px 4px"
    >[设置信用审核未通过]</span>
    <span
      v-if="data.creditInfo&&data.creditInfo.processDefinitionKey==='creditChange'&&data.creditInfo.flowStatus==='DOING'"
      class="flow-status-color"
      style="padding:0px 4px"
    >[调整信用审核中]</span>
  </div>
</template>

<script>
import {reactive, toRefs} from 'vue'

export default {
  props: {
    data: {
      type: Object,
      default: () => {},
    },
    types: {
      type: String,
      default: 'list',
    },
  },
  setup() {
    const state = reactive({
      count: 0,
    })

    return {
      ...toRefs(state),
    }
  },
}
</script>

<style lang="scss" scoped>
</style>
